local mopai = fk.CreateSkill{
  name = "mopai"
}

Fk:loadTranslationTable{
  ["mopai"] = "摸牌",
  [":mopai"] = "摸任意张牌"
}

mopai:addEffect("active", {
  target_filter = Util.FalseFunc,
  card_filter = Util.FalseFunc,
  can_use = Util.TrueFunc,
  on_use = function (self, room, effect)
    local choices = {}
    local number = 1
    for i = 1, 99 do
      table.insert(choices, tostring(i))
    end
    number = tonumber(room:askToChoice(effect.from, {choices = choices, skill_name = mopai.name})) or 1
    effect.from:drawCards(number, mopai.name)
  end
})

return mopai